package com.bm.server.controller;


import com.bm.server.dto.LotteryDto;
import com.bm.server.service.intf.LotteryService;
import com.bm.server.vo.R;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import org.springframework.web.bind.annotation.CrossOrigin;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import javax.annotation.Resource;

@RestController
@RequestMapping("api/lottery/")
@Api(tags = "抽奖的相关操作-李松洋")
@CrossOrigin
public class LotteryController {
    @Resource
    private LotteryService service;
    @ApiOperation(value = "骗他五连抽")
    @PostMapping("five.do")
    public R five(LotteryDto dto){
        return service.five(dto);
    }
    @PostMapping("one.do")
    @ApiOperation(value = "骗一次")
    public  R one(LotteryDto dto){
        return service.one(dto);
    }
}
